<%@ page language="java" import="java.util.*" pageEncoding="utf-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core"  prefix="c"%>
<%@ taglib uri="http://struts.apache.org/tags-html"  prefix="html"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <base href="<%=basePath%>">
    <link href="CSS/Accessible_Design.css" rel="stylesheet" type="text/css" />
    <title>文件上传下载</title>
    
	<meta http-equiv="pragma" content="no-cache">
	<meta http-equiv="cache-control" content="no-cache">
	<meta http-equiv="expires" content="0">    
	<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
	<meta http-equiv="description" content="This is my page">
	<!--
	<link rel="stylesheet" type="text/css" href="styles.css">
	-->

  </head>
  
  <body>
  <html:form action="selectFile.do">
    <table width="590" height="114" border="1" cellspacing="0" class="small">
  <tr>
    <td height="17" colspan="6"><div align="center"><strong>文件上传下载</strong></div></td>
  </tr>
  <tr>
    <td height="25" colspan="6">文件名
      <input type="text" name="fileName" />
      <input type="submit" name="Submit" value="查询" />
      <a href="FilesUpLoad.jsp">上传文件</a></td>
  </tr>
  
  <tr>
    <td width="107">文件名</td>
    <td width="99">发送人</td>
    <td width="130">内容简介</td>
    <td width="112">下载</td>
  </tr>
 
  <c:forEach items="${fileList}" var="files">
  <tr>
   <html:hidden property="file" value="${files.fileId}"/>
    <td>${files.fileName}</td>
    <td>${files.login.name }</td>
    <td>${files.fileContent}</td>
    <td>
    <a href="FileLoad.do?method=download&fid=${files.fileId}">下载文件</a>
    </td>
  </tr>
   </c:forEach>
</table>
</html:form>
	
  </body>
</html>
